package team.se.tms.service;

import team.se.tms.dto.CourseDetail;
import team.se.tms.dto.CourseLabelDetail;
import team.se.tms.dto.Page;
import team.se.tms.dto.TeachingDetail;
import team.se.tms.po.TeachCourseInfo;

import java.util.List;

/**
 * 授课信息业务层接口,定义了授课信息业务层调用的方法
 *
 * @author winkyle
 * @date 2018/12/7
 */
public interface TeachCourseInfoService {
    /**
     * 根据用户id获取用户选课的课程详情
     *
     * @param userId 用户id
     * @param page 分页
     * @return 课程详情
     * @throws Exception 异常
     * @create on 2018/12/7 by winkyle
     */
    List<CourseDetail> listCourseDetails(String userId, Page page) throws Exception;

    /**
     * 查询全部授课详情
     *
     * @param page 分页
     * @return
     * @throws Exception
     * @create on 2018/12/8 by qingx
     */
    List<CourseDetail> listAllCourseDetails(Page page) throws Exception;

    /**
     * 查询修改课程时加载的信息
     *
     * @return
     * @throws Exception
     * @create on 2018/12/12 by qingx
     */
    TeachingDetail getModifyTeachingDetail(String teachCourseId) throws Exception;

    /**
     * 修改授课信息
     *
     * @param teachCourseInfo
     * @param stuIds
     * @return
     * @throws Exception
     * @create on 2018/12/18 by qingx
     */
    boolean modifyTeachCourseInfo(TeachCourseInfo teachCourseInfo,String[] stuIds) throws Exception;


    /**
     * 查询创建课程时加载的信息
     *
     * @return
     * @throws Exception
     * @create on 2018/12/18 by qingx
     */
    TeachingDetail getCreateTeachingDetail() throws Exception;

    /**
     * @create on 2018/12/28 by argentum
     *
     * @param userId
     * @return
     * @throws Exception
     */
    List<TeachCourseInfo> listTeachCourseInfos(String userId) throws Exception;

    /**
     * 添加授课信息
     *
     * @param teachCourseInfo
     * @param stuIds
     * @return
     * @throws Exception
     * @create on 2018/12/27 by qingx
     */
    boolean saveTeachCourseInfo(TeachCourseInfo teachCourseInfo,String[] stuIds) throws Exception;


    /**
     * 查询全部授课信息
     *
     * @param page 分页
     * @return
     * @throws Exception
     * @create on 2018/12/28 by qingx
     */
    List<TeachCourseInfo> listAllTeachCourseInfos(Page page) throws Exception;

    /**
     * 根据标签库id查询授课信息
     *
     * @param laeblLibId 标签库id
     * @return String 页面地址
     * @throws Exception 异常
     * @create on 2018/12/31 by johnny
     */
    List<TeachCourseInfo> listTeachCourseInfosByLabelLibId(String laeblLibId) throws Exception;


    List<CourseLabelDetail> listTeachCourseLabelDetails(List<String> teachCourseIdList) throws Exception;
}
